package com.qqtech.qquan.draw.service;

import java.util.List;

import javax.annotation.Resource;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.data.domain.Pageable;
import org.springframework.stereotype.Service;

import com.qqtech.core.frame.dao.BaseDao;
import com.qqtech.core.frame.service.BaseServiceImpl;
import com.qqtech.qquan.draw.dao.DrawBatchDao;
import com.qqtech.qquan.draw.model.DrawBatch;
import com.qqtech.qquan.draw.model.DrawBatchQuery;
import com.qqtech.qquan.draw.model.DrawBatchVo;

@Service
public class DrawBatchServiceImpl extends BaseServiceImpl<DrawBatch> implements DrawBatchService {
	public static final Logger log = LoggerFactory.getLogger(DrawBatchServiceImpl.class);

	@Resource
	private DrawBatchDao drawBatchDao;

	@Override
	protected BaseDao<DrawBatch> getBaseDao() {
		return drawBatchDao;
	}

	@Override
	public int updateMinusQuantity(Integer id) {
		return drawBatchDao.updateMinusQuantity(id);
	}

	@Override
	public List<DrawBatchVo> queryList4Draw(DrawBatchQuery drawBatchQuery, Pageable pageable) {
		return drawBatchDao.queryList4Draw(drawBatchQuery, pageable);
	}
}